<?php
/**
 * Created by PhpStorm.
 * User: 王松
 * Time: 2017/6/18 14:59
 */

namespace App\Transformers;

use App\Models\MarriageHistory;
use League\Fractal\TransformerAbstract;

class MarriageHistoryTransformer extends TransformerAbstract
{
    /**
     * @param \App\Models\MarriageHistory $author
     * @return array
     */
    public function transform(MarriageHistory $author)
    {
        $transform = [
            'id'           => $author->id,
            'marriage'     => $author->marriage,
            'macrosomia'   => $author->macrosomia,
            'menstruation' => $author->menstruation,
            'menopause'    => $author->menopause,
            'remark'       => $author->remark,
        ];

        return $transform;
    }


}